﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace MengLin.OOP.DesignPattern.TemplateMethod.Interest
{
    /// <summary>
    /// 抽象类
    /// </summary>
    public abstract class AbstractMethod
    {
        /// <summary>
        /// 抽象方法
        /// </summary>
        public abstract void Show();
    }

    /// <summary>
    /// 抽象类的子类
    /// </summary>
    public class ChildAbstractMethod : AbstractMethod
    {
        /// <summary>
        /// 覆写抽象方法
        /// </summary>
        public override void Show()
        {
            Console.WriteLine($"{nameof(ChildAbstractMethod)}");
        }
    }
}
